package cn.edu.bnu.bnuboy.xiaohua;




import com.baidu.mobads.InterstitialAd;

import net.youmi.android.AdManager;
import net.youmi.android.banner.AdSize;
import net.youmi.android.banner.AdView;
import net.youmi.android.spot.SpotManager;
import cn.edu.bnu.bnuboy.fragments.ReciteList;
import android.os.Bundle;
import android.view.View;
import android.widget.LinearLayout;

public class IndexActivity extends FragmentBaseActivity {
	@Override
	protected void onCreate(Bundle arg0) {
		super.onCreate(arg0);
		
		//有米广告
		AdManager.getInstance(this).init("15824bde653da667", "cd5ce4beb2be1559", false);
		SpotManager.getInstance(this).loadSpotAds();
		SpotManager.getInstance(this).showSpotAds(this);
	}
	public void showMenu(View v){
		menu.showMenu();
	}
	@Override
    protected void onDestroy() {
            SpotManager.getInstance(this)
                            .unregisterSceenReceiver();
            super.onDestroy();
    }
	@Override
	public void main() {
		// TODO Auto-generated method stub
		setContentView(R.layout.main);
		// 实例化广告条
//		AdView adView = new AdView(this, AdSize.FIT_SCREEN);
//		 获取要嵌入广告条的布局
//		LinearLayout adLayout=(LinearLayout)findViewById(R.id.adLayout);
//		 将广告条加入到布局中
//		adLayout.addView(adView);
		this.switchContent(new ReciteList());
	}
	
}
